Skip to content

whenxuan: update the time series augmentation and unittest#43

Merged
wwhenxuan merged 12 commits intomainfrom
master
Mar 10, 2026
Merged

whenxuan: update the time series augmentation and unittest#43
wwhenxuan merged 12 commits intomainfrom
master

Conversation

@wwhenxuan
Copy link
Copy Markdown
Owner

This pull request introduces a new Gaussian Mixture Model (GMM) simulator, expands and improves test coverage for time series augmentation methods, and makes several enhancements and minor cleanups to the codebase. The most significant changes include the addition of the GaussianMixtureSimulator class, new and improved tests for augmentation functions, and enhancements to the add_linear_trend augmentation. Some previously existing tests for file saving/loading have also been commented out.

New Features

  • Added GaussianMixtureSimulator class in s2generator/simulator/gaussia_mixture.py to enable fitting and sampling of time series data using a Gaussian Mixture Model, with methods for fitting, transforming, and accessing component statistics.
  • Added new module file s2generator/simulator/kalman_filtering.py as a placeholder for future Kalman filtering functionality.

Augmentation Improvements

  • Enhanced add_linear_trend in s2generator/augmentation/_time_transformation.py by adding a normalize parameter, improving trend scaling logic, and updating the docstring for clarity. [1] [2] [3]
  • Removed a debugging print statement from empirical_mode_modulation in _empirical_mode_modulation.py.

Testing Enhancements

  • Added comprehensive tests for time series mixup, linear trend addition, empirical mode modulation, and Wiener filtering to tests/test_augmentation.py, improving coverage of augmentation functions.
  • Commented out tests related to saving and loading NPY/NPZ/S2 data in tests/test_tools.py, possibly due to instability or pending updates.

Minor Code Cleanups

  • Minor formatting and readability improvements in val_diff method in s2generator/base.py.

@wwhenxuan wwhenxuan merged commit 978d4f3 into main Mar 10, 2026
1 check passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant